<script type="text/javascript" src="javascript/ajax.js"></script>
<?php 
	
	$q = $_GET['q'];

	
	if (!isset($_SESSION)) {
		session_start();
	}

	require("akses.php");
	require("managesession.php");
	connect();
	
$hasil = getContentDetail($q);
$komen = $hasil['user_comments'];


for ($i=0; $i<sizeof($komen); $i++)
					{

						$apalah = $komen[$i];
						$selisih = getContentTimeInterval($apalah['waktu']);
							echo " <div class='comment_list'>
								<div class='komen_content'>
									<div class='avatarkonten'><img src='${apalah['avatar_path']}' />
									</div>
									<div class=/commenkonten'>
										<a href='profil.php?id=${apalah['ID_user']}'> <strong>  ${apalah['username']}  </strong> </a>
										<br />
										<strong> ${selisih['selisih']} ${selisih['satuan']} </strong>
										<h5> '${apalah['isi']}' </h5>"
										. (((isLogin() == true) && ($apalah['ID_user'] == getLoginUserid())) ? "<button class='deleteCommentButton'  type='button' onclick='submitdelete($q, ${apalah['ID_komentar']})'> Delete </button>" : "") .
									"</div>
								</div>					
						</div>"; 
						
					}

?>